package com.app.game.bet.simple;

import com.app.game.other.Credit;

public class BetOddEven extends BetOneToOne{
	public static enum Type{ODD,EVEN}
	
	private Type type;
	
	public BetOddEven(Type type) {
		super();
		this.type = type;
	}
	
	@Override
	protected boolean isWin(int result){
		result = result%2;
		if(result == 1 && type == Type.ODD){
			return true;
		}
		if(result == 0 && type == Type.EVEN){
			return true ; 
		}
		return false;
	}
}
